package com.blog.common;

import lombok.Data;

/**
 * @author jiafujun
 * 2020-05-15 16:58:03
 **/
@Data
public class FlieResult {
    private Integer success;

    private String message;

    private String url;

    public FlieResult() {

    }

    public FlieResult(Integer success, String message, String url) {
        this.success = success;
        this.message = message;
        this.url = url;
    }

    public static FlieResult ok(String url) {
        return new FlieResult(1, "上传成功", url);
    }

    public static FlieResult error(String message) {
        return new FlieResult(0, message, null);
    }
}
